// const cluster = require('cluster');
// const numCPUs = require('os').cpus().length;
const { spawn } = require('child_process');
const config=require('./config');
for(let i=0;i<config.dockers.length;i++){
    const ls = spawn('node',['fork/docker',`${config.dockers[i].ip}`,`${config.dockers[i].port}`,`${config.dockers[i].type}`]);
    ls.stdout.on('data', (data) => {
        console.log(`stdout: ${data}`);
    });

    ls.stderr.on('data', (data) => {
        console.log(`stderr: ${data}`);
    });
}